import service from '@/utils/request'

const FinanceApi = {
    // ------------------财务管理------------------
  addInvoice: function (data) {
    return service.post('openRecord/addData', data)
  },
  editInvoice: function (data) {
    return service.put('openRecord/editData', data)
  },
  deleteInvoice: function (data) {
    return service.put('openRecord/logicDeleteById', data)
  },
  getInvoice: function (data) {
    // 获取单个信息
    return service.get('openRecord/getOpenRecordInfoById',{ params: data });
  },
  listInvoice: function (data) {
    return service.get('openRecord/pageData', {params: data })
  },
  getInvoiceExport: function (data) {
    // 导出excal表格
    return service.get('openRecord/listOpenRecordForExport',{ params: data });
  },

  auditInvoices: function (data) {
    return service.post('billOpenAmount/auditInvoices', data)
  },
  getByCardAndName: function (data) {
    return service.get('billOpenAmount/getByCardAndName', { params: data })
  },

}

export default FinanceApi
